﻿@model Tecnosop.WebUI.Models.ClienteViewModel
@{
    ViewBag.Title = "Editar un cliente";
    Layout = "~/Views/Cliente/_LayoutCliente.cshtml";
}
@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>Datos cliente</legend>
        <div class="editor-label">@Html.LabelFor(model => model.RUT_CLIENTE)</div>
        <div class="editor-field">
            @Html.HiddenFor(model => model.RUT_CLIENTE)
            @Html.DisplayFor(model => model.RUT_CLIENTE)
@*            @Html.EditorFor(model => model.RUT_CLIENTE)
            @Html.ValidationMessageFor(model => model.RUT_CLIENTE)*@
        </div>

        <div class="editor-label">@Html.LabelFor(model => model.REGION)</div>
        <div class="editor-field">
            @Html.DropDownList("REGION", String.Empty)
@*            @(Html.Telerik().DropDownList()
                .Name("Regiones")
                .HtmlAttributes(new { style = "width: 300px;" })
                .BindTo(ViewBag.REGION)
                .SelectedIndex(0)
            )*@
            @Html.ValidationMessageFor(model => model.REGION)
        </div>

        <div class="editor-label">@Html.LabelFor(model => model.NOMBRE)</div>
        <div class="editor-field">
            @Html.EditorFor(model => model.NOMBRE)
            @Html.ValidationMessageFor(model => model.NOMBRE)
        </div>

        <div class="editor-label">@Html.LabelFor(model => model.DIRECCION)</div>
        <div class="editor-field">
            @Html.EditorFor(model => model.DIRECCION)
            @Html.ValidationMessageFor(model => model.DIRECCION)
        </div>

        <div class="editor-label">@Html.LabelFor(model => model.CUIDAD)</div>
        <div class="editor-field">
            @Html.EditorFor(model => model.CUIDAD)
            @Html.ValidationMessageFor(model => model.CUIDAD)
        </div>

        <div class="editor-label">@Html.LabelFor(model => model.COMUNA)</div>
        <div class="editor-field">
            @Html.EditorFor(model => model.COMUNA)
            @Html.ValidationMessageFor(model => model.COMUNA)
        </div>

        <div class="editor-label">@Html.LabelFor(model => model.EMAIL)</div>
        <div class="editor-field">
            @Html.EditorFor(model => model.EMAIL)
            @Html.ValidationMessageFor(model => model.EMAIL)
        </div>

        <div class="editor-label">@Html.LabelFor(model => model.TELEFONO_1)</div>
        <div class="editor-field">
            @Html.EditorFor(model => model.TELEFONO_1)
            @Html.ValidationMessageFor(model => model.TELEFONO_1)
        </div>

        <div class="editor-label">@Html.LabelFor(model => model.TELEFONO_2)</div>
        <div class="editor-field">
            @Html.EditorFor(model => model.TELEFONO_2)
            @Html.ValidationMessageFor(model => model.TELEFONO_2)
        </div>

        <div class="editor-label">@Html.LabelFor(model => model.GIRO)</div>
        <div class="editor-field">
            @Html.EditorFor(model => model.GIRO)
            @Html.ValidationMessageFor(model => model.GIRO)
        </div>

        <br />
        <hr />
        <p>
            <button type="submit" class="nice radius small green button">Guardar Cambios</button>
            @Html.ActionLink("Cancelar", MVC.Cliente.VerTodos(), new { @class = "nice radius small red button" })
        </p>
    </fieldset>
}
